package com.dragon.mmochat.message;

import com.dragon.mmochat.MmochatConstant;
import com.skymobi.buffer.SkymobiBuffer;
import com.skymobi.message.SkymobiProtocolMessage;

public class Mmochat_11_1S extends SkymobiProtocolMessage {
	int mapId;
	byte line;
	int roleId;
	String chatMsg;

	public Mmochat_11_1S() {
		setMsgCode(MmochatConstant.MSGCODE_MMOCHAT_S_11_1);
	}

	@Override
	protected void encodeBody(SkymobiBuffer out) {
		out.putInt(mapId);
		out.put(line);
		out.putInt(roleId);
		out.putPrefixedString(chatMsg, 1);
	}

	public void setMapId(int mapId) {
		this.mapId = mapId;
	}

	public void setLine(byte line) {
		this.line = line;
	}

	public void setRoleId(int roleId) {
		this.roleId = roleId;
	}

	public void setChatMsg(String chatMsg) {
		this.chatMsg = chatMsg;
	}

}